<!-- this part is duplicate from cartMenu  keep it for mobile -->
<div class="navbar-cart collapse">
    <div class="cartMenu col-lg-4 col-xs-12 col-md-4 ">
        <div class="w100 miniCartTable scroll-pane">
            <table action-remove="<?php echo page_url('cart/delete-item'); ?>">
                <tbody>
                    <?php foreach($this->cart->contents() as $index=>$item){ ?>
                    <tr class="miniCartProduct">
                        <td style="20%" class="miniCartProductThumb">
                            <div>
                                <a href="<?php echo shop_product_url($this->shop->getSlug(), $item['options']['slug']); ?>"> 
                                    <img src="<?php echo product_upload($item['options']['image'], $item['options']['shop_image_folder']); ?>" alt="<?php echo $item['name']; ?>">
                                </a> 
                            </div>
                        </td>
                        <td style="40%">
                            <div class="miniCartDescription">
                                <h4> <a class="text-uppercase" href="<?php echo shop_product_url($this->shop->getSlug(), $item['options']['slug']); ?>"> <?php echo $item['name']; ?> </a> </h4>
                                <span class="size"> <?php echo $item['options']['code']; ?> </span>
                                <div class="price"> <span> <?php echo currency_format($item['price']); ?> </span> </div>
                            </div>
                        </td>
                        <td  style="10%" class="miniCartQuantity"><a > X <?php echo $item['qty']; ?> </a></td>
                        <td  style="15%" class="miniCartSubtotal"><span> <?php echo currency_format($item['subtotal']); ?> </span></td>
                        <td  style="5%" class="delete"><a href="#" class="btn-remove-cart-item" item="<?php echo $item['rowid']; ?>"> x </a></td>
                    </tr>
                    <?php } ?>
                </tbody>
            </table>
        </div>
        <!--/.miniCartTable-->
        <div class="clearfix"></div>
        <div class="miniCartFooter  miniCartFooterInMobile text-right">
            <h3 class="text-right subtotal"> Tổng giá trị: <?php echo currency_format($this->cart->total()); ?> </h3>
            <a href="<?php echo page_url('gio-hang', array('ref'=>shop_url($this->shop->getSlug()))); ?>" class="btn btn-sm btn-danger text-uppercase"> <i class="fa fa-shopping-cart"> </i> Giỏ hàng </a>
            <a href="<?php echo page_url('gio-hang', array('ref'=>shop_url($this->shop->getSlug()))); ?>#thanh-toan" class="btn btn-sm btn-primary text-uppercase"> Thanh toán </a>
        </div>
        <!--/.miniCartFooter-->
    </div>
    <!--/.cartMenu-->
</div>
<!--/.navbar-cart-->

<!--- this part will be hidden for mobile version -->
<div class="nav navbar-nav navbar-right hidden-xs">
    <div class="dropdown cartMenu ">
        <a href="#" class="dropdown-toggle" data-toggle="dropdown">
            <i class="fa fa-shopping-cart"></i> 
            <span class="cartRespons">
                Giỏ hàng (
                <span class="no_product cart-total-item" data-href="<?php echo page_url('cart/count'); ?>">
                    <?php echo $this->cart->total_items() > 0 ? $this->cart->total_items() : "trống"; ?>
                </span>
                )
            </span> 
            <b class="caret"> </b> 
        </a>
        <div class="dropdown-menu col-lg-4 col-xs-12 col-md-4 ">
            <div class="w100 miniCartTable scroll-pane">
                <table action-remove="<?php echo page_url('cart/delete-item'); ?>">
                    <tbody>
                        <?php foreach($this->cart->contents() as $index=>$item){ ?>
                        <tr class="miniCartProduct">
                            <td style="width:20%" class="miniCartProductThumb">
                                <div>
                                    <a href="<?php echo shop_product_url($this->shop->getSlug(), $item['options']['slug']); ?>">
                                        <img src="<?php echo product_upload($item['options']['image'], $item['options']['shop_image_folder']); ?>" alt="<?php echo $item['name']; ?>">
                                    </a>
                                </div>
                            </td>
                            <td style="width:40%">
                                <div class="miniCartDescription">
                                    <h4> <a class="text-uppercase" href="<?php echo shop_product_url($this->shop->getSlug(), $item['options']['slug']); ?>"> <?php echo $item['name']; ?> </a> </h4>
                                    <span class="size"> <?php echo $item['options']['code']; ?> </span>
                                    <div class="price"> <span> <?php echo currency_format($item['price']); ?> </span> </div>
                                </div>
                            </td>
                            <td  style="width:10%" class="miniCartQuantity"><a > X <?php echo $item['qty']; ?> </a></td>
                            <td  style="width:15%" class="miniCartSubtotal"><span> <?php echo currency_format($item['subtotal']); ?> </span></td>
                            <td  style="width:5%" class="delete"><a href="#" class="btn-remove-cart-item" item="<?php echo $item['rowid']; ?>"> x </a></td>
                        </tr>
                        <?php } ?>
                    </tbody>
                </table>
            </div>
            <!--/.miniCartTable-->
            <div class="clearfix"></div>
            <div class="miniCartFooter text-right">
                <h3 class="text-right subtotal"> Tổng giá trị: <?php echo currency_format($this->cart->total()); ?> </h3>
                <a href="<?php echo page_url('gio-hang', array('ref'=>shop_url($this->shop->getSlug()))); ?>" class="btn btn-sm btn-danger text-uppercase"> <i class="fa fa-shopping-cart"> </i> Giỏ hàng </a>
                <a href="<?php echo page_url('gio-hang', array('ref'=>shop_url($this->shop->getSlug()))); ?>#thanh-toan" class="btn btn-sm btn-primary text-uppercase"> Thanh toán </a>
            </div>
            <!--/.miniCartFooter-->
        </div>
        <!--/.dropdown-menu-->
    </div>
    <!--/.cartMenu-->

    <div class="search-box">
        <div class="input-group">
            <button class="btn btn-nobg getFullSearch" type="button"> <i class="fa fa-search"> </i> </button>
        </div>
        <!-- /input-group -->
    </div>
    <!--/.search-box -->
</div>
        <!--/.navbar-nav hidden-xs-->